home *** CD-ROM | disk | FTP | other *** search
/ The Hacker Chronicles - A…the Computer Underground / The Hacker Chronicles - A Tour of the Computer Underground (P-80 Systems).iso / network / nia27 < prev    next >
Text File  |  1992-09-26  |  24KB  |  567 lines

  1.   ZDDDDDDDDDDDDDDDDDD? IMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM; ZDDDDDDDDDDDDDDDDDD?
  2.   3   Founded By:    3 :  Network Information Access   : 3 Mother Earth BBS 3
  3.   3 Guardian Of Time 3D:            12APR90            :D3  NUP:> DECnet    3
  4.   3   Judge Dredd    3 :       Guardian Of Time        : 3Text File Archives3
  5.   @DDDDDDDDBDDDDDDDDDY :            File 27            : @DDDDDDDDDBDDDDDDDDY
  6.            3           HMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM<           3
  7.            3            IMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM;          3
  8.            @DDDDDDDDDDDD: VMS: System Manager's Manual  :DDDDDDDDDDY
  9.                         :         Chapter 4.11          :
  10.                         HMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM<
  11. Here is Chapter 4 of 11 Chapters,  concerning the VMS: System Manager's
  12. Manual.  Once you have download all 11 chapters,  you will be able to
  13. enter a Vax system and hack your own accounts with the greatest of ease.
  14.  
  15.                               MANAGING USERS
  16.  
  17. As a system manager,  it is your job to create and maintain user accounts
  18. on the system.  To create accounts for users and effectively manage the
  19. use of the system, you must determine which users need access to the
  20. system and what system resources they require.
  21.  
  22. Once you understand user needs, you can establish controls that customize
  23. the system appropriately.
  24.  
  25. The VMS operating system provides the Authorize Utility (AUTHORIZE) to
  26. authorize and control the use of system resources by individual users.
  27. This chapter describes the use of AUTHORIZE to do the following:
  28.  
  29. :     Add a user account
  30. :  Modify a user account
  31. :  Remove a user account
  32. :  List the user accounts
  33.  
  34. See the Authorize Utility chapter in the Reference section for some
  35. information on AUTHORIZE.
  36.  
  37. 4.1 THE USER AUTHORIZATION FILE (UAF)
  38.  
  39. You manage VMS users by creating and maintaining user accounts,  which
  40. control who can log in to the system and how it can be used.  Use the
  41. Authorize Utility (AUTHORIZE) to do the following:
  42.  
  43. :  Create new records and modify existing records in the system user
  44.        authorization file (SYS$SYSTEM:SYSUAF.DAT) and the network user
  45.        authorization file (SYS$SYSTEM:NETPROXY.DAT)
  46.  
  47. :  Create new records and modify existing records in the rights
  48.        database file (SYS$SYSTEM:RIGHTSLIST.DAT)
  49.  
  50. Whenever a user logs in,  the system uses the information contained in the
  51. user authorization file (UAF) to validate the login attempt, establish the
  52. account's environment, and create a process with appropriate attributes.  In
  53. this way, the system restricts users to the resources you assign to each
  54. account.
  55.  
  56. As system manager, you may want to create a private copy of SYSUAF.  DAT
  57. in a directory other than SYS$SYSTEM as an emergency backup for the system
  58. SYSUAF.DAT file.  Note that, to have an effect on user processes, any
  59. private version of SYSUAF.DAT must be copied to the SYS$SYSTEM directory
  60. and have the system user identification code (UIC).
  61.  
  62. Because certain images (such as MAIL and SET) require access to the system
  63. UAF and are normally installed with the SYSPRV privilege, make certain that
  64. you always grant system access to SYSUAF.DAT.  The authorization files are
  65. created with the following default protection:
  66.  
  67. SYSUAF.DAT     S:RWED, 0:RWED, G, W
  68. NETPROXY.DAT   S:RWED, 0:RWED, G:RWED, W
  69. RIGHTSLIST.DAT S:RWED, 0:RWED, G:RWE, W:R
  70.  
  71. If you need to maximize the protection for SYSUAF.DAT or NETPROXY.DAT, use
  72. the following DCL command (note, however, that RIGHTSLIST.DAT MUST BE
  73. WORLD-READABLE);
  74.  
  75. $ SET PROTECTION=(S:RWED, O,G,W)SYSTEM$SYSTEM: FILENAME
  76.  
  77. Using the Authorize Utility,  you create and maintain UAF records by
  78. assigning values to various fields within each record.  The values you
  79. assign identify the user, define the user's work environment,  and control
  80. use of system resources.
  81. EXAMPLE 4-1 presents a typical UAF record for a nonprivileged user
  82. account.
  83.  
  84. To gain access to a specific user record, set the default directory to
  85. SYS$SYSTEM, enter the command RUN AUTHORIZE to invoke the Authorize
  86. Utility,  and enter the command SHOW username at the UAF> prompt.  You can
  87. then enter AUTHORIZE commands and such as ADD and MODIFY to create new
  88. user accounts or change the information in the fields of an existing UAF
  89. account.
  90.  
  91. EXAMPLE 4-1: SAMPLE UAF RECORD DISPLAY
  92.  
  93. $ SET DEFAULT SYS$SYSTEM
  94. $ RUN AUTHORIZE
  95. UAF> SHOW WELCH
  96.  
  97. USERNAME:  WELCH        OWNER:   ROB WELCH
  98. ACCOUNT:   INVOICE         UIC:  [21.51 ([INV.WELCH])
  99. CLI:      DCL           TABLES: DCTABLES
  100. DEFAULT:   USER3: [WELCH]
  101. LGICMD:
  102. LOGIN FLAGS:
  103. PRIMARY DAYS:  MON TUE WED THU FRI
  104. SECONDARY DAYS:          SAT SUN
  105. NO ACCESS RESTRICTIONS
  106. EXPIRATION:       (NONE)   PWDIMINIMUM: 6  LOGIN FAILS: 0
  107. PWDLIFETIME:      (NONE)  PWCHANGE:    15APR88 13:58
  108. LAST LOGIN:       (NONE)  (INTERACTIVE), (NONE) (NON-INTERACTIVE)
  109. MAXJOBS: 0 FILLM:   20    BYTLM:    8192
  110. MAXACCTJOBS:   0 SHRFILLM: 0    PBYTOLM:     0
  111. MAXDETACH:  0 BIOLM:   10   JTQUOTA:   1024
  112. PRCLM:   2 DIOLM:   10   WSDEF:      150
  113. PRIO:            4 ASTLM:   10    WSQUO:   256
  114. QUEPRIO:    4 TQELM:   10   QSEXTENT:   512
  115. CPU:      (NONE) enqlm:   10   pgflquo:      10240
  116. Authorized Privileges:
  117.  TMPMBX NETMBX
  118. Default Privileges:
  119.  TMPMBX NETMBX
  120.  
  121. 4.1.1  SYSTEM-SUPPLIED UAF RECORDS
  122.  
  123. The Authorize Utility proves a set of commands and qualifiers to assign
  124. values to any field in a UAF record.  The software distribution with a new
  125. VMS system contains a UAF of four records:
  126.  
  127. :  DEFAULT - Serves as a template for creating user records in the
  128.        UAF.  A new user record is assigned the values of the DEFAULT
  129.        record except where you explicitly override those values.  Thus,
  130.        whenever you add a new account, you need only specify values for
  131.        fields that you want to be different.  For example, the following
  132.        AUTHORIZE command creates a new record having the same values as the
  133.        DEFAULT RECORD, except that the password, UIC, and default directory
  134.        fields are changed.
  135.  
  136.        UAF> ADD MARCONI/PASSWORD=QLP6YT9A/UIC=[033, 004]-
  137.        _UAF> /DIRECTORY=[MARCONI]
  138.  
  139.        Section 4.2 gives an example of how to use AUTHORIZE to add a user
  140.        account.
  141.  
  142.        NOTE: the default record cannot be renamed or deleted from the UAF.
  143.  
  144. :  FIELD - Permits DIGITAL Field Service personnel to check out a new
  145.        system.  The FIELD record should be disabled once the system is
  146.        installed.
  147.  
  148. :  SYSTEM - Provides a means for you to log in with full privileges.
  149.        The SYSTEM record can be modified but cannot be renamed or deleted
  150.        from the UAF.
  151.  
  152.        CAUTION: Do not change the SYSTEM account UAF record fields for the
  153.        default device and directory, and privileges.  Installation of VMS
  154.        maintenance releases and optional software products depends on
  155.    certain values in these fields.
  156.  
  157. :  SYSTEST - Provides an appropriate environment for running the User
  158.    Environment Test Package (UETP).  The SYSTEST record should be
  159.    disabled once the system is installed.
  160.  
  161. 4.1.2 GENERAL MAINTENANCE OF THE UAF
  162.  
  163. Usually, you use the UAF supplied with the distribution kit.  (You can,
  164. however, rename the UAF with the DCL command RENAME, and then create a new
  165. UAF with AUTHORIZE.)  You should limit any kind of access to this file to
  166. the SYSTEM account.  Furthermore, each time you modify the file, create a
  167. backup copy so that in case of a system failure you do not lost the
  168. modifications.  See Chapter 8 for procedures for backing up files.
  169.  
  170. The UAF is access as a shared file, and updates to the UAF are made on a
  171. per record basis, which eliminates the need for both a temporary UAF and a
  172. new version of the UAF after each AUTHORIZE session.  Updates become
  173. effective as soon as AUTHORIZE commands are entered, not after the
  174. termination of AUTHORIZE.  (For this reason, you should not enter
  175. temporary values with the intent of fixing them later in the session.)
  176.  
  177. After installing the system, you should make the following modifications
  178. to the UAF:
  179.  
  180. :  SYSTEM, FIELD, & SYSTEST ACCOUNTS: If the passwords on these accounts
  181.    are not secure or if they have not been changed recently, be sure to
  182.    change the passwords.  Use obscure passwords of six characters or more
  183.    and continue to change them on a regular basis.  You should not permit
  184.    general users access to these accounts.
  185.  
  186.    In addition to changing the password, you can disable an account,
  187.    especially if it is used infrequently.  To disable an account, specify
  188.    the following AUTHORIZE command:
  189.  
  190.    UAF> MODIFY username /FLAGS=DISUSER
  191.  
  192.    The login flag DISUSER disables the account and prevents anyone from
  193.    logging into the account.  To enable the account when it is needed, run
  194.    AUTHORIZE and specify MODIFY users /FLAGS=NODISUSER.  However, you
  195.    should be cautious about disabling the SYSTEM account, because some
  196.    optional software and some command procedures may not start up properly
  197.    if the SYSTEM account is disabled.
  198.  
  199.    CAUTION: Be careful not to disable all of your privileged system
  200.    accounts. If you inadvertently do so, you can recover by setting the
  201.    UAFALTERNATE SYSGEN parameter during a conversational bootstrap
  202.    operation. See Chapter 2 for information on emergency startup
  203.    procedures.
  204.  
  205. :  DEFAULT ACCOUNT: You may want to change several fields in this account.
  206.    For example:
  207.  
  208.    UAF> MODIFY DEFAULT/DEVICE=DISK$USER/WSQUO=750
  209.  
  210.    The default device is set to the name most commonly used for user
  211.    accounts that will be added.  Likewise the working set value is set to
  212.    a value appropriate for most users on the system.
  213.  
  214. Use the SYSTEM account only for system functions such as performing
  215. backups and installing maintenance updates.  The account comes to you with
  216. full privileges, so exercise caution in using it.  For example, because
  217. you have BYPASS privilege.  the system will allow you to delete any file
  218. no matter what its protection.  If you type an incorrect name or spurious
  219. asterisk, you may destroy files that you or other users need to keep.  For
  220. this reason, use another account with fewer privileges for day-to-day system
  221. management activities.
  222.  
  223. If you want to receive mail sent to the system account, use the SET
  224. FORWARD command in the MAIL Utility to have any SYSTEM mail forwarded to
  225. any other account.  To use the SET FORWARD command for this purpose, do
  226. the following:
  227.  
  228. 1. Make sure that you are logged in to the SYSTEM account.
  229. 2. Enter the MAIL Utility by entering the MAIL command at DCL Level.
  230. 3. At the MAIL> prompt, enter the command SET FORWARD username.
  231.  
  232. 4.2 ADDING A USER ACCOUNT
  233.  
  234. How you set up a user account depends on the needs of the individual user.
  235. In general, there are two types of accounts:
  236.  
  237. :  INTERACTIVE: A person using an interactive account has access to
  238.        the system software and can perform work of a general nature
  239.        (program development, text editing, and so on).  Usually, such an
  240.        account is considered individual; that is, only one person can use
  241.    it.
  242.  
  243. :  CAPTIVE: A person using a captive account (also called a turnkey or
  244.    application account) has access only to limited user software and
  245.    can only perform work that is limited to a particular function.
  246.    Access to a captive account is limited by function; that is, only
  247.    those who perform a particular function can use it.  For example,
  248.    you might develop an inventory system.  Anyone whose job entails
  249.    inventory control can access your system, but that person cannot
  250.    access other subsystems or the base software.
  251.  
  252. You should perform the following tasks in conjunction with adding a user
  253. account:
  254.  
  255. 1. Determine a user name and password.
  256. 2. Determine a unique user identification code (UIC).
  257. 3. Decide where the account's files will reside (the device and
  258.    directory).
  259. 4. Create a default directory on the appropriate volume, using the
  260.    following DCL command:
  261.  
  262.    $ CREATE/DIRECTORY directory-spec/OWNER_UIC= uic
  263. 5.    Determine the security needs of the account (that is, the level of
  264.    file protection, privileges, and access control).
  265.  
  266. Once you analyze the purpose of a user account and decide which attributes
  267. and resources it requires, you can use the Authorize Utility to create the
  268. account.  Give yourself the SYSPRV privilege.  Then enter the following
  269. commands to set your default device and directory to that of SYS$SYSTEM
  270. and invoke the utility as follows:
  271.  
  272. $ SET DEFAULT SYS$SYSTEM
  273. $ RUN AUTHORIZE
  274.  
  275. When the utility responds with the UAF> prompt, use the AUTHORIZE command
  276. ADD to specify attributes in the UAF fields as shown in this example:
  277.  
  278. UAF>  ADD JONES/PASSWORD=LPB57WN/UIC=[014,1] -
  279. _UAF> /DEVICE=DISK$USER/DIRECTORY=[JONES] -
  280. _UAF> /LGICMD=DISK$USER: [NEWPROD]GRPLOGIN -
  281. _UAF> /OWNER="ROBERT JONES"/ACCOUNT=DOC
  282.  
  283. The /OWNER and /ACCOUNT entries are primarily for accounting purposes and
  284. can be omitted unless required by your site.  The following unspecified
  285. qualifiers usually take their default values from the DEFAULT record:
  286.  
  287. :  LIMITES and QUOTAS - (/ASTLM, /BIOLM, /CPUTIME, /DIOLM, ENQLM,
  288.    /FILLM, /]TQUOTA, /MAXACCTJOBX, /MAXDETACH, /MAXJOBS, /PGFLQUOTA,
  289.    /PRCLM, /SHRFILLM, /TQELM, /WSDEFAULT, /WSEXTENT, /WSQUOTA) - These
  290.    qualifiers impose limits on the use of resuable system resources;
  291.    the default values are adequate in most cases.
  292.  
  293. :  PRIORITY - (/PRIORITY, /QUEPRIORITY) - The default values are
  294.    usually adequate for accounts not running real-time processes.
  295.  
  296. :  PRIVILEGES - (/DEFPRIVILEGES, /PRIVILEGES) - The default privileges
  297.    (TMPMBX, NETMBX) are usually adequate, depending on the purpose of
  298.    the account.
  299.  
  300. :  PRIMARY & SECONDARY LOGIN TIMES; LOGIN FUNCTIONS - (/ACCESS,
  301.    /DIALUP, /FLAG, /INTERACTIVE, /LOCAL, /PRIMEDAYS, /REMOTE) - By
  302.    default, users are allowed to log in at any hour of any day.  To
  303.    override the setting of a particular day, use the DCL command SET
  304.    DAY.  Use this command if a holiday occurs on a day that would
  305.    normally be treated as a primary day and you want it treated as a
  306.       secondary day.
  307.  
  308.    The following example shows an AUTHORIZE command that adds a UAF
  309.    record of a captive account:
  310.  
  311.    UAF> ADD INVENTORY/PASSWORD=QRC7Y94A/UIC=[033,066] -
  312.    _UAF> /DEVICE=DISK$INVENT/DIRECTORY[INV]/LGICMD=INVENTORY -
  313.    _UAF> /FLAGS=CAPTIVE/NOACCESS=(PRIMARY, 18-8,SECONDARY, 0-23)
  314.  
  315.    In this example,  the /FLAGS and /NOACCESS qualifiers restrict
  316.    users from logging in to the captive account.  The /NOACCESS
  317.    qualifier limits logins to specific hours.  The /FLAGS=CAPTIVE
  318.    qualifier adds the login flag CAPTIVE to the captive account
  319.    record.  The CAPTIVE flag locks the person using the account into
  320.    the application software by doing the following:
  321.  
  322.    :  Disabling the CTRL/Y function to prevent users from
  323.       interrupting the execution of the command procedure and
  324.       gaining access to the command interpreter
  325.  
  326.    :  Preventing the user from specifying an alternate command
  327.       interpreter with the /CLI qualifier at login time
  328.  
  329.    :  Preventing the user from specifying an alternate default
  330.       disk device with the /DISK qualifier at login time
  331.  
  332.    The following examples summarize the steps for setting up an
  333.    individual user account and a captive account:
  334.  
  335. $ SET DEFAULT SYS$SYSTEM
  336. $
  337. $ RUN AUTHORIZE
  338. UAF>ADD JONES -      ! User name
  339. _/PASSWORD=ROCKET -     ! Password
  340. _/UIC=[014,1] -      ! UIC
  341. _/ACCOUNT=DOC -      ! Accounting Group Name
  342. _/OWNER="ROCKET JONES"     ! Owner
  343. _/DEVICE=$DISK1 -    ! Default directory
  344. _/DIRECTORY=[JONES]
  345. UAF>EXIT
  346. $
  347. $ ! Create top-level directory for individual
  348. $ CREATE/DIRECTORY $DISK1: [JONES] -
  349. _$ /OWNER_UIC=[DOC,JONES] -
  350. _$ /PROTECTION=(S:RWE,0:RWE,G:RE,W:RE)
  351. $
  352.  
  353. 4.3 SETTING UP A CAPTIVE ACCOUNT WITH AUTHORIZE
  354.  
  355. You use the automatic login facility (ALFMAINT) to set up a terminal that
  356. accepts automatic logins from authorized users.  For example, a terminal
  357. might be set up for the account INVENTORY, which automatically logs a user
  358. into a captive account when INVENTORY is specified as the user name.
  359.  
  360. First, you must follow the steps described in the previous sections to
  361. create the toplevel default directory and add the account.  Once the
  362. account has been added, you set your default directory to SYS$MANAGER and
  363. invoke the ALFMAINT command procedure.  ALFMAINT prompts you for the name
  364. of the terminal that you want assciated w/ the user name of the automatic
  365. login account.
  366.  
  367. The following example summarizes the steps for setting up automatic logins
  368. for an individual user account and a captive account:
  369.  
  370. INDIVIDUAL ACCOUNT W/ AUTOMATIC LOGIN
  371.  
  372. $ SET DEFAULT SYS$SYTEM
  373. $
  374. $ RUN AUTHORIZE
  375. UAF>ADD JONES -      ! Username
  376. _/PASSWORD= -        ! Null password
  377. _/UIC=[014,1] -      ! UIC
  378. _/ACCOUNT=DOC!                 ! Accounting group name
  379. _/OWNER="ROCKET JONES" -   ! Owner
  380. _/DEVICE=$DISK1 -    ! Default directory
  381. _/DIRECTORY=[JONES] -
  382. UAF>EXIT
  383. $
  384. $ ! Create top-level directory for individual
  385. $ CREATE/DIRECTORY $DISK1:  [JONES] -
  386. _$/OWNER_UIC=[DOC,JONES]
  387. _$/PROTECTION=(S:RWE, O:RWE, G:RE, W:RE)
  388. $
  389. $ SET DEFAULT SYS$MANAGER
  390. $
  391. $ @ALFMAINT
  392.  
  393. Enter the name of the terminal thatt you would like to set for
  394. automatic login, or a blank line or EXIT to exit.
  395.  
  396. terminal (ddcu)? TTA1           ! Assigned terminal
  397. Username? JONES
  398. Terminal (ddcu)? EXIT
  399.  
  400. CAPTIVE ACCOUNT W/ AUTOMATIC LOGIN
  401.  
  402. $ SET DEFAULT SYS$SYSTEM
  403. $
  404. $ RUN AUTHORIZE
  405. UAF>ADD INVENTORY -                ! Username
  406. _/PASSWORD= -                      ! Null password
  407. _/UIC=[033,066] -                  ! UIC
  408. _/ACCOUNT=INV -                    ! Accounting group name
  409. _/LGICMD=$DISK1:[INVENTORY]LOGIN   ! Login File
  410. _/ACCESS=(PRIMARY,8-17) -          ! No off hours
  411. _/FLAGS=CAPTIVE                    ! All flags on
  412. UAF>EXIT
  413. $
  414. $ SET DEFAULT SYS$MANAGER
  415. $ @ALFMAINT
  416.  
  417. Enter the name of the terminal that you would like to set for
  418. automatic login, or a blank line or EXIT to exit.
  419.  
  420. Terminal (ddcu)? TTA0                   ! All terminals
  421. Username? INVENTORY                     ! on automatic
  422. Terminal (ddcu)? TTA1                   ! login except
  423. Username? INVENTORY                     ! the console terminal
  424. Terminal (ddcu)? TTA2                   ! (the console terminal
  425. Username? INVENTORY                     ! for this system is TTA4)
  426. Terminal (ddcu)? TTA3
  427. Username? INVENTORY
  428. Terminal (ddcu)? EXIT
  429.  
  430. 4.4 MODIFYING A USER ACCOUNT
  431.  
  432. Use the AUTHORIZE command MODIFY to change any of the fields in an existing,
  433. user account.  For exmple, the following command is used to change user
  434. WELCH's password:
  435.  
  436. UAF> MODIFY WELCH/PASSWORD=newpassword
  437.  
  438. 4.5 LISTING USER ACCOUNTS
  439.  
  440. Use the AUTHORIZE command LIST to create the file SYSUAF.LIS containing a
  441. summary of all user records in the UAF, as follows:
  442.  
  443. UAF> LIST
  444. %UAF-I-LISTMSG1, writing listing file
  445. %UAF-I-LISTMSG2, listing file SYSUAF.LIS complete
  446.  
  447. By default, the LIST command produces a brief report conatining the following
  448. information from the UAF:
  449.  
  450. :       ACCOUNT OWNER
  451. :       USER NAME
  452. :       UIC
  453. :       ACCOUNT NAMES
  454. :       PRIVILEGES
  455. :       PROCESS PRIORITY
  456. :       DEFAULT DISK AND DIRECTORY
  457.  
  458. Use the /FULL qualifier to create a full report of all the information
  459. contained w/in the UAF, as follows:
  460.  
  461. UAF> LIST/FULL
  462. %UAF-I-LISTMSG1, writing listing file
  463. %UAF-I-LISTMSG2, listing file SYSUAF.LIST complete
  464.  
  465. 4.6 DELETEING A USER ACCOUNT
  466.  
  467. The main problem in deleting an account, especially an interactive account
  468. is cleaning up the files used by the account.  The following steps are
  469. suggested:
  470.  
  471. 1.  Copy (or have the outgoing user of the account copy) any files of value
  472.     to the ownership of another account.  Be sure to change the owner UIC of
  473.     the files to match the owner UIC of the new owner.  You can also use the
  474.     Backup Utility ( BACKUP ) to copy the files to a backup tape or disk.
  475.  
  476. 2.  Change the password, and log in to the account that you want to delete.
  477.     ( By working from a nonprivileged account, you can avoid inadvertently
  478.     deleting files that may be owned by an account other than the one that
  479.     you want to delete.)
  480.  
  481. 3.  Delete the account's files and directories from the deepest level up to
  482.     the to level using the following procedure:
  483.  
  484.     a.  Locate and examine all subdirectories using the DCL command DRECTORY
  485.         [default ... ], where default is the name of the account's default
  486.         directory.
  487.     b.  Delete the files in each subdirectory and then delete the
  488.         subdirectory. Note that directory files are protected against owner
  489.         deleteion, therefore, you must change the protection before deleting
  490.         directory files.
  491.     c.  Delete the account's top-level directory.  Example 4-2 Illustrates a
  492.         command procedure that deletes an account's files from the bottom
  493.         level up.
  494.  
  495.         NOTE:  the command procedure in Example 4-2 should not be executed
  496.                from a privileged account.
  497.  
  498. 4.  Remove the account, using the Authorize Utility.
  499.  
  500. 5.  Remove the user's disk quota entry from the disk quota file, if one
  501.     existed, w/ the SYSMAN UTILITY.
  502.  
  503. 6.  Remove associated VAXmail information by entering the MAIL command REMOVE
  504.     username.
  505.  
  506. EXAMPLE 4-2:  COMMAND PROCEDURE TEMPLATE FOR DELETING AN ACCOUNT'S FILES
  507.  
  508. $ !          DELTREE.COM -- Deletes a complete directory tree
  509. $ !          P1 = pathname of root of tree to delete
  510. $ !          All files and directories in the tree, including
  511. $ !          the named root, are deleted.
  512. $ !
  513. $ IF "'DELTREE'" .EQS. "" THEN DELTREE = "@SYS$LIBRARY:DELTREE"
  514. $ ON CONTROL_Y THEN GOTO DONE
  515. $ ON WARNING THEN GOTO DONE
  516. $ DEFAULT = F$LOGICAL ("SYS$DISK" + F$DIRECTORY ()
  517. $10:
  518. $ IF P1 .NES. "" THEN GOTO 20
  519. $ INQUIRE P1 "ROOT"
  520. $ GOTO 10
  521. $20:
  522. $ IF F$PARSE(P1) .EQS. "" THEN OPEN FILE 'P1'
  523. $ SET DEFAULT 'P1'
  524. $LOOP:
  525. $ FILESPEC = F$SEARCH("*.DIR;1")
  526. $ IF FILESPEC .EQS. "" THEN GOTO LOOPEND
  527. $ DELTREE [.'F$PARSE(FILESPEC..."NAME")']
  528. $ GOTO LOOP
  529. $LOOPEND:
  530. $ IF F$SEARCH(+*.*;*") .NES. "" THEN DELETE *.*;*
  531. $ DIR = (F$DIRECTORY()-"]"-">")-F$PARSE("[-]"...-
  532.          "DIRECTORY")-"]"-">")-"."-"["-"<"
  533. $ SET PROTECTION=WORLD:RWED [-]'DIR'.DIR;1
  534. $ DELETE [-]'DIR'.DIR;1
  535. $DONE:
  536. $ SET DEFAULT 'DEFAULT'
  537.  
  538. If you never assign multiple users the same UIC, you can use the Backup
  539. Utility to remove the user's files, even if the files are scattered
  540. throughout the directory structure.  The following is an example of a BACKUP
  541. command used to remove files.
  542.  
  543. $ BACKUP/DELETE PUBLIC:[...]/OWNER=[21,103] MTAO:PUBLICUIC.SAV
  544.  
  545. This BACKUP command copies and deletes only those files owned by the specified
  546. UIC on disk PUBLIC.  The files are copied into a save set named PUBLICUIC on
  547. device MTA0.  Note that the BACKUP/DELETE command does not delete the
  548. directory files (file extension DIR) for the account.
  549.  
  550. DISABLING A USER ACCOUNT
  551.  
  552. If you want to disable an account w/out deleting it, set the disable user
  553. flag (/FLAGS=DISUSER) using AUTHORIZE. If the user is logged in, the account
  554. is diabled only after the user logs out.
  555.  
  556. Disabling a powerful yet infrequently used account provides an extra security
  557. mesasure by eliminating the risk of guessed or stolen passwords.
  558.  
  559. $EOF
  560.  
  561. [OTHER WORLD BBS]
  562.  
  563.  
  564.  
  565.  
  566. Downloaded From P-80 International Information Systems 304-744-2253 12yrs+
  567.